package com.highcom;

import com.alibaba.druid.pool.DruidDataSource;
import com.highcom.service.UserService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Main {
    public static void main(String[] args) {
        ApplicationContext ctx = new ClassPathXmlApplicationContext("applicationContext.xml");
        //System.out.println("ctx = " + ctx);
        //UserService userService = (UserService) ctx.getBean("userService");
        //userService.save();

         DruidDataSource dataSource = (DruidDataSource) ctx.getBean("dataSource");
        System.out.println("dataSource = " + dataSource);
    }
}